package constant

import (
	"gitee.com/sansaniot/ssiot-core/msg/sms/model"
	"time"

	"gitee.com/sansaniot/ssiot-core/msg/email"
	gocache "github.com/patrickmn/go-cache"
)

const (
	// jwt负载信息
	JwtKeyUserInfo     = "user"
	JwtKeyUserId       = "userId"
	JwtKeyUserName     = "username"
	JwtKeyUserRoleIds  = "roleIds"
	JwtKeyUserRoleName = "roleName"
	JwtKeyUserDeptIds  = "deptIds"
	JwtKeyUserDeptName = "deptName"
	JwtKeyAgencyId     = "agency"
	JwtKeyAppId        = "appId"
	// 设备简讯缓存
	DeviceEasyCache = "dev_cache"
	// 告警主题
	AlarmNotifyTopic = "/san/alarm/notify"
	// 默认分组id
	DefaultGroupId = "root"
	// 设备分组缓存
	DeviceDeptCache = "DEVDEPT"
	// 敏感内容加密加盐
	SALTKEY = "ssiot_aes_len_16"
)

var (
	//配置文件
	ConfigFile = "config/settings.yml"

	// 本地缓存
	LocalCache = gocache.New(10*time.Second, 3*time.Second)

	SmsConfig   model.SMSConfig
	EmailConfig email.EmailConfig
)
